Remove unused variable and check if the widget is a GtkWidget subclass,
authorJohan Dahlin <jdahlin@async.com.br>
Fri, 20 Jun 2008 14:19:22 +0000 (14:19 +0000)
committerJohan Dahlin <johan@src.gnome.org>
Fri, 20 Jun 2008 14:19:22 +0000 (14:19 +0000)
2008-06-20  Johan Dahlin  <jdahlin@async.com.br>

    * gtk/gtkwidget.c (gtk_widget_get_allocation): Remove unused variable
    and check if the widget is a GtkWidget subclass, not the uninitialized
    allocation.

svn path=/trunk/; revision=20644

ChangeLog
gtk/gtkwidget.c

index 023a8d9e8adf9063cc47239534ed991b3d30ce71..a87fb571654686fb4259b68d3e679a4e619bb567 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+2008-06-20  Johan Dahlin  <jdahlin@async.com.br>
+
+       * gtk/gtkwidget.c (gtk_widget_get_allocation): Remove unused variable
+       and check if the widget is a GtkWidget subclass, not the uninitialized
+       allocation.
+
 2008-06-20  Michael Natterer  <mitch@imendio.com>
 
        * gtk/gtkaccellabel.h
index 16a3aec5098d846fe1f36e4652294f8aab7e919c..1c4c305e4d7fc5fddd427886e716dba28c745b9e 100644 (file)
@@ -9899,8 +9899,7 @@ gtk_widget_get_has_tooltip (GtkWidget *widget)
 GtkAllocation
 gtk_widget_get_allocation (GtkWidget *widget)
 {
-  GtkAllocation allocation;
-  g_return_val_if_fail (GTK_IS_WIDGET (widget), allocation);
+  g_return_val_if_fail (GTK_IS_WIDGET (widget), widget);
 
   return widget->allocation;
 }